﻿using LangRenGameLib.Card.Skill;
using LangRenGameLib.Enum;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace LangRenGameLib.Card.Info
{
    /// <summary>
    /// 角色的基本信息，如是否死亡等
    /// </summary>
    class CardInfo
    {
        public Card Owner;

        /// <summary>
        /// 是否已经死亡
        /// </summary>
        public bool IsDie
        {
            get;
            private set;
        }

        /// <summary>
        /// 是否具有投票权
        /// </summary>
        public bool HaveVote
        {
            get;
            private set;
        }

        /// <summary>
        /// 被投票数
        /// </summary>
        public int PushVote
        {
            get;
            private set;
        }

        /// <summary>
        /// 角色被查验时以什么身份接受查验
        /// </summary>
        public Card CheckCard;

        /// <summary>
        /// 击杀角色
        /// </summary>
        public void GoDie(DieType type)
        {
            foreach(CardSkill i in Owner.Skill)
            {
                i.OnDie(type);
            }

            IsDie = true;
        }
    }
}
